public class Main {
    public static void main(String[] args) {
        Son son = new Son();
        son.method();
    }
}

class Parent {
    Parent() {
        System.out.println("Parent's Constructor without parameter");
    }

    Parent(boolean b) {
        System.out.println("Parent's Constructor with a boolean parameter");
    }

    public void method() {
        System.out.println("Parent's method()");
    }
}

class Son extends Parent {
    // 构造方法：调用父类带布尔参数的构造函数
    Son() {
        super(true); // 显式调用父类的带参构造函数
        System.out.println("Son's Constructor without parameter");
    }

    @Override
    public void method() {
        System.out.println("Son's method()");
        super.method(); // 调用父类的 method 方法
    }
}7-15 